package com.song.mybatis_test;

import com.song.dao.BlogMapper;
import com.song.dao.SequenceDao;
import com.song.dao.bean.Blog;
import org.apache.ibatis.executor.BatchResult;
import org.apache.ibatis.session.ExecutorType;
import org.apache.ibatis.session.SqlSession;
import org.apache.ibatis.session.SqlSessionFactory;
import org.apache.ibatis.session.SqlSessionFactoryBuilder;
import org.junit.Test;

import java.io.File;
import java.io.FileInputStream;
import java.io.FileNotFoundException;
import java.io.InputStream;
import java.util.List;

/**
 * @Description: test：类描述
 * @author: songzhangyong
 * @Date: 2019/11/9 10:56
 */

public class BlogTest {

    static SqlSessionFactory factory = MyBatisExecutorTest.factory;
    static SqlSession session = MyBatisExecutorTest.session;



    @Test
    public void executor_simple() {

        BlogMapper blogMapper = session.getMapper(BlogMapper.class);

        Blog blog = blogMapper.selectBlogById2(1);

        System.out.println(blog);


    }

}
